#ifndef _GPU_PARSER_H_
#define _GPU_PARSER_H_


#include <string>
#include "pugixml.hpp"
#include "GpuQuery.h"
#include "GpuDimension.h"

class GpuParser{
private:
	pugi::xml_document doc;
public:
	GpuParser(std::string xmlFile);

	std::string getAppType();
	std::string getSearchPhase();
	std::string getInvertedListPath();
	std::string getInvertedIndexLengthFile();
	std::string getSearchMethod();
	int getNumOfDocToExpand();
	int getTotalDimension();	
	int getTopK();	
	std::vector<int> getMinDomainForAllDimension();	
	std::vector<int> getMaxDomainForAllDimension();	
	//const char* getWeight();
	//const char* getAggregateFunction();
	
	void getQuerySet(std::vector<GpuQuery> &querySet);
	void getDimensionSetForQuerySet(pugi::xml_node root, std::vector<GpuDimension> &dimensionSet, int& dimensionSetSize);
};

#endif
